<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Profile extends MY_Controller  {
	
	function __construct(){
		parent::__construct();
		$this->load->model('profile_model');
	}
	
	public function show_profilebyemail() {
		
	}
	
	public function view() {
		$this->data['query'] = $this->profile_model->show_profile($this->session->userdata['userid']);
		$this->render_page('profile_view');
	}
	
	public function edit() {
		$this->data['query'] = $this->profile_model->show_profile($this->session->userdata['userid']);
		$this->render_page('profile_edit_view');
	}
	
	public function process() {
		$result = $this->profile_model->edit_profile($this->session->userdata['userid']);
		$this->view();
	}
	
}